<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@taglib prefix="s"  uri="/struts-tags"%>

<title>合同贷款查询</title><span id="navlink">合同管理 >> 合同贷款查询</span>

<input type="text" id="abc" value="" />
<input type="text" id="def" value="" />
<div id="top_area">
	<input type="button" id="search" value="查找"/>
	<input type="button" id="ajax" value="ajax"/>
</div>

<table class="table_box table_bottom_border" cellspacing="0" cellpadding="0">
	<tr>
		<th style="width: 150px;"><b>合同编号</b></th>
		<th style="width: 150px;"><b>合同名称</b></th> 
		<th style="width: 150px;"><b>借款方</b></th> 
		<th style="width: 150px;"><b>借款金额</b></th> 
		<th style="width: 150px;"><b>到期时间</b></th>
		<th ><b>操作</b></th> 
	</tr>
<s:iterator value="htList" status="index" var="var">
	<tr>
		<td style="text-align:center">${htId}</td>
		<td style="text-align:center">${htName}</td>
		<td style="text-align:center">${jkfName}</td>
		<td style="text-align:center"><s:text name="f.number.two"><s:param value="jkje"/></s:text></td>
		<td style="text-align:center"><s:text name="f.date.ymd"><s:param value="hkrqDate"/></s:text></td>
		<td style="text-align:center">
<s:if test='option=="all"'>
<s:form action="showContract" method="post" style="margin:0px;display:inline;">
<input type="hidden" name="i" value="${htId}">
<s:submit name="detail" value="详情" method="detail"/>
</s:form>
</s:if><s:elseif test='option=="delay"'>
<s:form action="baseContractDefer" method="post" style="margin:0px;display:inline;">
<input type="hidden" name="htId" value="${htId}">
<s:submit name="defer" value="展期" method="defer"/>
</s:form>
</s:elseif>
<input type="button" class="getid" value="仅测试"/>
		</td>
	</tr>
</s:iterator>
</table>
<div id="button_area">
<div id="button_area"><div class="pagebar"></div></div>
</div> 

<script>
$("#search").click(function(){
	$( "#dialog-search" ).dialog({
		resizable: false,
	    modal: true
	});
});
$("#ajax").click(function(){
	OpenDialog(600,400,"查找","contractList!contractA");
});


$(".getid").click(function(){
	$("#abc").val($(this).parent("td").parent("tr").children("td:eq(1)").text());
	$("#def").val($(this).parent("td").parent("tr").children("td:eq(2)").text());
});
</script>

<div id="dialog-search" style="display:none" title="查询">
	<form action="aaaa_action" method="get">
	合同编号：<input type="text" value="" /><br /><br />
	签定日期：<input type="text" value="" />
	<div style="float:right">
	<input type="submit" value="查询" />
	</div>
	</form>
</div>